package com.xh.bussiness.tiku.constant;

import lombok.Data;

@Data
public class PaperWidthConstant {
    //    // 题号宽度
    public final Double INDEX_WIDTH = 10.0;

    public final Double CLONE_INDEX_WIDTH = 20.0;

    // 页面总宽度
    public final Double TOTAL_WIDTH = 480.0;
    // 题干宽度
    public final Double TITLE_WIDTH = 470.0;

    // 阅读理解、完形填空分隔符ABCD距离左侧的宽度
    public final Double QUESTION_SPLIT_WIDTH = 200.0;

    // 单选题和多选题的选项宽度
    public final Double ONE_OPTION_WIDTH = 470.0;
    public final Double TWO_OPTION_WIDTH = 235.0;
    public final Double FOUR_OPTION_WIDTH = 117.5;

    //    // 完形填空和阅读理解的选项宽度
    public final Double CLONE_ONE_OPTION_WIDTH = 450.0;
    public final Double CLONE_TWO_OPTION_WIDTH = 225.0;
    public final Double CLONE_FOUR_OPTION_WIDTH = 112.5;


    //
    public static final Double ANSWER_WIDTH = 46.0;
    public static final Double ANSWER_CONTENT_WIDTH = 414.0;

    public static PaperWidthConstant getInstance(Integer type) {
        //A4
        if (type == 1) {
            return new PaperWidth_A4_Constant();
        }
        //8K
        if (type == 2) {
            return new PaperWidth_8K_Constant();
        }
        return new PaperWidthConstant();
    }
}
